package com.example.demo.config;

public class DemoVolidate {

    private static  volatile boolean isOver = false;

    public static void main(String[] args) {
        new Thread(()->{
            while (!isOver);
        }).start();
        try {
            Thread.sleep(500);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        isOver =true;
    }
}
